\chapter{Introduction}

\section{\headset}
HeaDSET is a suite of programs for planning, recording and playing back brain tumour operations. For you as third-party developer, \headset gives a number of hooks where third-party code can be inserted. 
Most third-party code will interact with the PathRecorder application, since the third-party interfaces are geared to provide support for device input. These interfaces are well tested and are used by \headset to provide some features. HeaDSET even comes with a number of simple examples to show you how to use these interfaces. These examples show how simple it is to extend the system. And if that is not enough, you can always look at the build-in functionality and see that they use the same interfaces as you will.  
In the last part of the dictionary we look inside \headset and take a more detailed look deep inside the system. We look at the "engine" of \headset and see how the HDT file standard works. And as such we hope to give an overview of how \headset can be extended via the official API and to give a picture how to implement even more advanced extensions. Together with the design document, the API documentation and this manual you should be able to get a fairly detailed overview of how \headset can be expanded.

\section{Tools}
Since \headset is written in Python, we expect that extensions are written in Python as well. It is possible to make extensions in C/C++ by using Python extension mechanisms. \footnote{These can in general be found here http://docs.python.org/extending/} But in this manual we will only focus on extending \headset by using Python. And for C/C++ to work, some small bit of interface code should be written in Python. 
\headset does not limit your access to Python. So if it can be used with Python, it can be used in your extension. If your example uses a TCP connection to communicate to the outside world, you could for example use Python's build-in TCP/IP functionality to couple \headset with your device. 
For the second part of the manual we will also look at the snake Publisher-Subscriber "profiler". This can be a useful tool for getting a feel of how the system works inside.

\section{Versions}
All APIs that can be used, are documented and contain version numbers. The developers of HeaDSET will maintain compatibility between minor versions. An API added to a lower minor version will continue to work in a higher minor version. But APIs added to higher minor versions will not work with a lower minor version. Breaking API changes will lead to a major version number change. And at this time we recommend that you only use the API defined by version 1.0, even if the interfaces state a higher 1.x version for greater compatibility. 
While a lot of functionality can be implemented via the plug-in interface, not all functionality is available via documented APIs. Some functionality requires you to modify the system. In this manual we also provide some details how different parts of \headset communicate with each other. 
